# -*- coding: utf-8 -*-
# @Author  : gaoyu
# @Time    : 2024/9/25 3:52 PM
# @Function: 

import json
import os
from dotenv import load_dotenv
from loguru import logger

load_dotenv()

# 数据库查询配置
WATER_DATABASE_URL = os.getenv("WATER_DATABASE_URL", "postgresql://postgres:water@172.20.7.85:5432/qgis")

# 数据库配置
WATER_DATABASE_CONFIG = json.loads(os.getenv("WATER_DATABASE_CONFIG", "{}"))
WATER_MAIN_DATABASE_CONFIG = json.loads(os.getenv("WATER_MAIN_DATABASE_CONFIG", "{}"))
# 冷备
MINIO_COLD_ACCESS_KEY = os.getenv("MINIO_COLD_ACCESS_KEY", "mFkAU3Paat5WH4v1")
MINIO_COLD_SECRET_KEY = os.getenv("MINIO_COLD_SECRET_KEY", "ExpCtwb39lwt128w7YOZCgu79cWxa2Q2")
MINIO_COLD_ENDPOINT = os.getenv("MINIO_COLD_ENDPOINT", "https://172.20.4.2:9000/")
# 桶名
GRIDS_ORIGIN = os.getenv("GRIDS_ORIGIN", "grids-origin")
GFS_ORIGIN = os.getenv("GFS_ORIGIN", "gfs-origin")
# CDN连接
CDN_URL = os.getenv("CDN_URL", "http://172.20.7.86:6081")
# 钉钉配置
DING_APP_KEY = os.getenv("DING_APP_KEY", "dingfsqlevmcqerdbtig")
DING_APP_SECRET = os.getenv("DING_APP_SECRET", "eTl94YEIis7ScUAWHRaFc-ENWtD7WNtUrU2rprhA8AbHTxHUYrGZvoZVwL40tbsO")

if __name__ == '__main__':
    logger.info(WATER_DATABASE_URL)
    logger.info(WATER_DATABASE_CONFIG)
